

import type { Isystemgroup } from './entity';
import type { IPageParams } from '@/types/table'
import request from '@/api/request'

export function getPageList(params: IPageParams) {
  return request({
    url: `admin/system/group/list`,
    method: 'get',
    params,
    loading: true
  })
}

export function systemgroupDel(id) {
  return request({
    url: `admin/system/group/delete`,
    method: 'get',
    params: { id }
  })
}
export function systemgroupinfo(id) {
  return request({
    url: `admin/system/group/info`,
    method: 'get',
    params: { id }
  })
}
export function systemgroupSelect(id) {
  return request({
    url: `admin/system/group/select`,
    method: 'get',
    params: { id }
  })
}

export function systemgroupAddup(data) {
  return request({
    url: `admin/system/group/${!data.id ? 'save' : 'update'}`,
    method: 'post',
    params: data,
  })
}
